<% content_for :css do %>
  <%= stylesheet_link_tag 'users_new_or_edit' %>
<% end %>
<% content_for :title do %>修改我自己的基本资料<% end %>
<%= form_for @user,
      :url => update_current_user_url(@user),
      :method => :put,
      :html => {
        :id => :user_form
      } do |f| %>
<div class="grid_12 user">
  <div class="grid_12 head alpha omega">
    <div class="grid_12 title">
      修改我自己的基本资料
    </div>  
    <% if flash[:success].present? %>
    <div id='success' class="grid_8">
      <div><%= flash[:success] %></div>
    </div>         
    <% end %>
    <div class="grid_12 line">
      <div class="grid_2">姓名</div>
      <div class="grid_9">
        <%= f.text_field :full_name %>
      </div>
    </div>
    <div class="grid_12 line">
      <div class="grid_2">性别</div>
      <div class="grid_9">
        <%= f.radio_button :sex, :unknown, :class => :no %> <%= label :user,:sex_unknow, t(:unknown) %>
      <%= f.radio_button :sex, :man, :class => :no %> <%= label :user,:sex_man, t(:man)  %>
      <%= f.radio_button :sex, :woman, :class => :no %> <%= label :user,:sex_woman, t(:woman)  %>
      </div>
    </div>
    <div class="grid_12 line">
      <div class="grid_2">手机号</div>
      <div class="grid_9">
        <%= f.text_field :mobile %>
      </div>
    </div> 
    <div class="grid_12 line">
      <div class="grid_2">邮箱</div>
      <div class="grid_9">
        <%= f.text_field :email %>
      </div>
    </div>
  </div>
  <div class="grid_12 alpha body">  
    <div class="grid_12 line">
      <div class="grid_2">地址</div>
      <div class="grid_9">
        <%= f.label :address, '添加地址描述', :id => :label_for_user_address, :class => @user.address.blank? ? '' : :hidden %>
        <%= f.text_field :address %>
        <%= label_js_for :user_address %>
      </div>
    </div> 
  </div>  
  <div class="grid_12 bottom">
    <div class="grid_10">
      <%= f.submit "更新我自己的基本资料" %><small>或</small><%= link_to "返回", current_user_url   %>
    </div>
  </div>  
</div>
<% end %>